﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Threading;
using System.Globalization;

namespace MikeKappel.Com.CS
{
    public static partial class Globalization
    {
	    public static void SetCulture(String[] cultures, String Default)
	    {
            SetCulture((cultures == null || cultures.Length == 0) ? Default : HttpContext.Current.Request.UserLanguages[0]);
	    }
        public static void SetCulture(String culture)
	    {
            Thread.CurrentThread.CurrentCulture = CultureInfo.CreateSpecificCulture(culture);
            Thread.CurrentThread.CurrentUICulture = CultureInfo.CreateSpecificCulture(culture);
	    }
    }
}
